import React from 'react';


export default () => {
    const [count, setCount] = React.useState(0);

    const add = React.useCallback(() => {
        setCount(count + 2);
    }, [count]);

    const conterStyle = {
        margin: '16px'
    }
    return (
        <div style={conterStyle}>
            <button onClick={add}>Click Me</button>
            <div>Click Count:{count}</div>
        </div>
    )
}